package com.insurance.service;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.service.IService;
import com.insurance.common.utils.PageUtils;
import com.insurance.entity.AuthenticationEnterpriseEntity;

import java.util.List;
import java.util.Map;

/**
 * 企业业务接口类
 * @date 2021-02-25 17:20:28
 */
public interface AuthenticationEnterpriseService extends IService<AuthenticationEnterpriseEntity> {

    PageUtils queryPage(Map<String, Object> params, QueryWrapper<AuthenticationEnterpriseEntity> queryWrapper);

    QueryWrapper<AuthenticationEnterpriseEntity> getQueryWrapper(AuthenticationEnterpriseEntity authenticationEnterpriseEntity);

    /**
     * 通过企业证件号查询企业
     * @param cardId
     * @return
     */
    AuthenticationEnterpriseEntity getByCardId(String cardId);

    /**
     * 通过企业证件号查询企业
     * @param cardId
     * @param appId
     * @return
     */
    AuthenticationEnterpriseEntity getByCardIdAndAppId(String cardId, String appId);

    /**
     * 通过证件号校验企业是否注册过
     *
     * @param cardId 证件号
     * @return
     */
    boolean validateByCardId(String cardId);

    /**
     * 通过主键集合查询
     *
     * @param idList 主键集合
     * @return
     */
    List<AuthenticationEnterpriseEntity> queryEnterpriseListByIds(List<String> idList);

    /**
     * 查询企业集合
     *
     * @param authenticationEnterprise 查询条件
     * @return
     */
    List<AuthenticationEnterpriseEntity> queryEnterprise(AuthenticationEnterpriseEntity authenticationEnterprise);

}

